package com.example.demo.mapper;


import com.example.demo.pojo.Account;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;
import org.springframework.stereotype.Repository;

import java.util.List;

@Mapper
@Repository
public interface AccountMapper {

    List<Account> selectAll();

    void addAccount(@Param("account") Account account);

    Account selectAccountById(@Param("s_id")int id);

    void updateAccount(@Param("account")Account account);

    Account checkAccount(String username);

    List<Account> getAccountsByConditions(@Param("text") String conditionText, @Param("type") String conditionType);

    void updatePwd(@Param("pwd")String pwd, @Param("s_id") Integer s_id);
}
